package line;
import point.ObjectPoint;
import environment.Simulation;


/**
 * 
 * @author Robert C. Duvall
 */
public class Spring extends Line {

/**
 * 
 * @param start start point
 * @param end   end point
 * @param length rest length
 * @param kVal k factor
 */
    public Spring(final ObjectPoint start, final ObjectPoint end,
            final double length, final double kVal) {
        super(start, end, length, kVal);

    }
/**
 * @param canvas container
 * @param dt time
 */
    public final void update(final Simulation canvas, final double dt) {
        applyHookesForce(getmyK(), getDistance());
    }

}
